package mediator.chat;

public class Main {

	public static void main(String[] args) {

		AbstChatMediator chatPlatform = new ChatMediator();

		ConcreteColleague u1 = new ConcreteColleague(chatPlatform, "c语言");

		ConcreteColleague u2 = new ConcreteColleague(chatPlatform, "c++语言");

		ConcreteColleague u3 = new ConcreteColleague(chatPlatform, "java语言");

		u1.join();
		u2.join();
		u3.join();

		System.out.println("----C语言群发消息----");
		u1.sendToAll("我是编程语言之祖");
		
		u3.sendToPerson("我会GC", "c语言");

	}

}
